<script type="text/javascript">
    function pic_upload_success(file, data) {
        var json = $.parseJSON(data)

        $(this).bjuiajax('ajaxDone', json)
        if (json[BJUI.keys.statusCode] == BJUI.statusCode.ok) {
            $('#j_custom_pic').val(json.filename)
            $('#j_custom_span_pic').html('已上传图片：<img src="/'+ json.filename +'" width="100">')
        }
    }
</script>
<div class="bjui-pageContent">
    <div class="bjui-doc">
        <h3 class="page-header">新增Banner</h3>
        <form method="post" action="{:U($Think.ACTION_NAME)}" data-toggle="validate" id="msg-push-form" class="pageForm" data-reload-navtab="true">
            <input type="hidden" name="uid" value="{$uid}" />
            <div class="row-fluid">
                <div class="control-group">
                    <label class="control-label">开机画面：</label>
                    <div class="controls">
                        <div style="display: inline-block; vertical-align: middle;">
                            <div id="j_custom_pic_up" data-toggle="upload" data-uploader="{:U('upload')}"
                                 data-file-size-limit="1024000000"
                                 data-file-type-exts="*.jpg;*.png;*.gif;*.mpg"
                                 data-multi="true"
                                 data-on-upload-success="pic_upload_success"
                                 data-icon="cloud-upload"></div>
                            <input type="hidden" name="imgs" value="" id="j_custom_pic" data-rule="required" data-msg-required="请上传开机画面">
                            <span id="j_custom_span_pic"></span>
                        </div>
                    </div>
                </div>
            </div>
        </form>
    </div>
</div>
<div class="bjui-pageFooter">
    <ul>
        <li><button type="button" class="btn-close" data-icon="close">取消</button></li>
        <li><button type="submit" class="btn-default" data-icon="save">保存</button></li>
    </ul>
</div>